-
-
Notifications
You must be signed in to change notification settings - Fork 746
fix incorrect rounding of final weight volume #12970
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
fix incorrect rounding of final weight volume #12970
Conversation
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Nice one 👍 Thanks @bouaik 🙏
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Thanks for fixing this and providing great documentation 📄 👍
end | ||
|
||
def down | ||
change_column :spree_line_items, :final_weight_volume, :decimal, precision: 10, scale: 2 |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Just noting that this action would be destructive.. but I guess if somebody was running the down
action they would be expecting that.
Hey @bouaik, Are you available to address these? Thank you. |
Moved this issue to In Progress so conflicts can be fixed. |
39d845e
to
ba3de62
Compare
Hi @filipefurtad0 - I've fixed the conflicts for this one, and it's ready for testing. Thanks. |
Hey @bouaik , Thanks for this fix. Before this PR, we see the bug occuring: After this PR, we can see rounding occurs correctly: We can also see this in the Orders and Fulfillment report, the previous order is marked in red / the new order is marked with the green dots: Interestingly, the variant size does not appear in brackets for all variants, only for the 35mL like so (Also, and out of scope: please notice, that changing the variant name also changes the naming in this report, for previously placed order. So it seems the information is being fetched from the product/variant names; wonder if the name should instead be fetched from the order instead.) |
@filipefurtad0 many thanks for this detailed testing, as always!
I could be wrong but maybe one is a display as and not the other? Otherwise weird indeed.
If this can be fixed quickly within this PR, maybe that's the best, as it seems we would introduce this here. What do you think @bouaik ?
very good catch. We need indeed to keep the name on previous orders. Our users can sometimes completely change the product. Line items should never change when product catalog changes. Let's open a different issue for that one. |
Hi @bouaik hope you are fine. |
What? Why?
Release notes
Changelog Category (reviewers may add a label for the release notes):
The title of the pull request will be included in the release notes.
Dependencies
Documentation updates